package org.pz.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationContext;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class TestController {

    @Autowired
    private ApplicationContext applicationContext;

    @RequestMapping("/test")
    public String test() {
        String t = applicationContext.getApplicationName() + "2";
        System.out.println( t );
        return t;
    }

}
